package com.company;

import java.util.ArrayList;

public class MonsterWolfSet {
    private ArrayList<MonsterWolf> MonsterWolves = new ArrayList<>();

    //增删改查
//    public MonsterWolf get(String id){
//        MonsterWolf monsterWolf=null;
//        for(MonsterWolf item:MonsterWolves){
//            if(true==id.equals(item.getId())){
//               monsterWolf=item;
//               break;
//            }
//        }
//        return monsterWolf;
//    }

    public MonsterWolf get(String id){
        MonsterWolf monsterWolf = null;
        for (MonsterWolf item:MonsterWolves
        ) {
            if (true==id.equals(item.getId())){
                monsterWolf=item;
                break;
            }
        }
        return monsterWolf;
    }

    public MonsterWolfSet() {
    }

    public MonsterWolfSet(ArrayList<MonsterWolf> monsterWolves) {
        MonsterWolves = monsterWolves;
    }

    public ArrayList<MonsterWolf> getMonsterWolves() {
        return MonsterWolves;
    }

    public void setMonsterWolves(ArrayList<MonsterWolf> monsterWolves) {
        MonsterWolves = monsterWolves;
    }
}
